<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>6-2 两列布局：table和table-cell</title>
  <style>
    .box {
      width: 100%;
      height: 50px;
      /* 父元素设置table => 相当于表格的table */
      display: table;
    }

    .left {
      width: 100px;
      height: 80px;
      background: green;
      color: white;
      /* 子元素设为table-cell => 相当于表格的td  */
      display: table-cell;
    }

    .right {
      /* 高度的话取最大值 */
      height: 150px;
      background: darkorange;
      color: white;
      /* 子元素设为table-cell => 相当于表格的td  */
      display: table-cell;
    }
  </style>
</head>

<body>

  <div class="box">
    <div class="left">left...</div>
    <div class="right">right...</div>
  </div>
</body>

</html>